let utils = getLocalValue('utils')
utils.printLog('画圆开始')
let mapStatus = getLocalValue('mapStatus');
let lng = data.lng;
let lat = data.lat;
utils.printLog('画圆的经纬度lng=' + lng + ',lat=' + lat);
console.log('画圆的经纬度lng=' + lng + ',lat=' + lat)
let f_circle = getLocalValue('f_circle');
let options = {
  steps: 256,
  units: 'meters',
  properties: {
    foo: 'bar'
  }
};

let cicleData = f_circle([lng, lat], 1000, options);
let cicleData1 = f_circle([lng, lat], 2000, options);
let cicleData2 = f_circle([lng, lat], 5000, options);



let finalLng = parseFloat(lng)
let finalLat = parseFloat(lat)

let returnJson =
  {
    "type": "FeatureCollection",
    "features": [
      {
        "type": "Feature",
        "geometry": {
          "type": "Polygon",
          "coordinates": []
        },
        "properties": {}
      },
      {
        "type": "Feature",
        "geometry": {
          "type": "Polygon",
          "coordinates": []
        },
        "properties": {}
      },
      {
        "type": "Feature",
        "geometry": {
          "type": "Polygon",
          "coordinates": []
        },
        "properties": {}
      },
      // {
      //   "type": "Feature",
      //   "properties": {
      //     "name": "2km"
      //   },
      //   "geometry": {
      //     "type": "Polygon",
      //     "coordinates": [
      //       [
      //         [finalLng, finalLat],
      //         cicleData[0],
      //         cicleData[0],
      //         [finalLng, finalLat]
      //       ]
      //     ]
      //   }
      // },
      // {
      //   "type": "Feature",
      //   "properties": {
      //     "name": "5km",
      //   },
      //   "geometry": {
      //     "type": "Polygon",
      //     "coordinates": [
      //       [
      //         [finalLng, finalLat],
      //         cicleData1[parseInt(cicleData1.length / 4)],
      //         cicleData1[parseInt(cicleData1.length / 4)],
      //         [finalLng, finalLat]
      //       ]
      //     ]
      //   }
      // }
    ]
  }

returnJson.features[0].geometry.coordinates.push(cicleData);
returnJson.features[1].geometry.coordinates.push(cicleData1);
returnJson.features[2].geometry.coordinates.push(cicleData2);


// utils.printLog('circleData', JSON.stringify(returnJson))
return returnJson